Configurable time and date visibility #75
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hello,
I use your theme everywhere I can : i3, JetBrains and tmux. So it's time to contribute to one of the configuration. 🙂
As I put my date and time in my i3 bar, I don't want to have it in my tmux.
I propose this patch to add some configuration in order to only have date, time or both displayed and keep a clean look. Both is the default to get some backward compatibility.
Here are some screen for the different possible configuration.
Colors may look darker because my background is dark and my terminal background is transparent.
I refactored a bit for the
NORD_TMUX_STATUS_DATE_FORMAT
to prevent too many deepif
s and set my two new variables the same way.I made an attempt on my machine to get a neater
status-right
value but it didn't worked so I ended up doing like so but if anyone has better to propose, I'll be happy to make some changes. As you can see I was forced to explode the different#[fg=...,bg=...]
into multiple#[fg=...]#[bg=...]...
otherwise it didn't work.A last thing that I didn't understood is that you put
tmux set-environment -gu NORD_TMUX_STATUS_TIME
and same for date and everything works as expected, we can change the option, reload configuration and changes is made.I tried to add my two new variables but in this case they are always considered as
0
so nothing is displayed. Again, if anyone can give me the answer, I'll be happy to learn.Thank you!